#include<stdio_ext.h>
#include<unistd.h>
#include<sys/types.h>
int main()
{
    pid_t id=fork();
    if(id<0)
    {
        perror("fork");
        return 1;
    }
    else if(id==0)
    {
        printf("I am child process:%d,id:%d\n",getpid(),id);
    }
    else{
         printf("I am father process:%d,id:%d\n",getpid(),id);
    }
    sleep(1);
    return 0;

}
